package com.boyadegroot.divelog.data;

import android.provider.BaseColumns;

public final class DiveLogDatabaseContract {

    public static final String DATABASE_NAME = "DiveLog.db";
    public static final int DATABASE_VERSION = 1;
            
    private static final String TEXT_TYPE = " TEXT";
    private static final String INTEGER_TYPE = " INTEGER";
    private static final String DATE_TYPE = " INTEGER";
    private static final String DATETIME_TYPE = " INTEGER";
    private static final String COORDINATE_TYPE = " REAL";
    private static final String DEPTH_TYPE = " REAL";
    private static final String WEIGHT_TYPE = " REAL";
    private static final String REAL_TYPE = " REAL";
    private static final String IPK_TYPE = " INTEGER PRIMARY KEY";
    private static final String UNIQUE_CONSTRAINT = " UNIQUE";
    private static final String NOTNULL_CONSTRAINT = " NOT NULL";
    private static final String FOREIGNKEY_CONSTRAINT = " FOREIGN KEY";
    private static final String COMMA_SEP = ",";
    
    public static final String COLUMN_NAME_COUNT = "count";
    public static final String COLUMN_NAME_STAT = "stat";

    // To prevent someone from accidentally instantiating the contract class, give it an empty constructor.
    public DiveLogDatabaseContract() {
    }

    public static abstract class Divers implements BaseColumns {

        public static final String TABLE_NAME = "divers";
        public static final String COLUMN_NAME_USERNAME = "username";
        public static final String COLUMN_NAME_FIRSTNAME = "firstname";
        public static final String COLUMN_NAME_LASTNAME = "lastname";
        public static final String COLUMN_NAME_BIRTHDATE = "birthdate";
        public static final String COLUMN_NAME_CERTIFICATION_ID = "certification_id";

        public static final String[] AllColumns = {
                Divers._ID,
                Divers.COLUMN_NAME_USERNAME,
                Divers.COLUMN_NAME_FIRSTNAME,
                Divers.COLUMN_NAME_LASTNAME,
                Divers.COLUMN_NAME_BIRTHDATE,
                Divers.COLUMN_NAME_CERTIFICATION_ID
        };
        
        public static final String SQL_DELETE_TABLE =
                "DROP TABLE IF EXISTS " + TABLE_NAME;
                
        public static final String SQL_CREATE_TABLE =
                "CREATE TABLE " + TABLE_NAME + " (" +
                        _ID + IPK_TYPE + COMMA_SEP +
                        COLUMN_NAME_USERNAME + TEXT_TYPE + UNIQUE_CONSTRAINT + NOTNULL_CONSTRAINT + COMMA_SEP +
                        COLUMN_NAME_FIRSTNAME + TEXT_TYPE + COMMA_SEP +
                        COLUMN_NAME_LASTNAME + TEXT_TYPE + COMMA_SEP +
                        COLUMN_NAME_BIRTHDATE + DATE_TYPE + COMMA_SEP +
                        COLUMN_NAME_CERTIFICATION_ID + INTEGER_TYPE + COMMA_SEP +
                        FOREIGNKEY_CONSTRAINT + "(" + COLUMN_NAME_CERTIFICATION_ID + ")" + " REFERENCES " + DiveCertifications.TABLE_NAME + "(" + DiveCertifications._ID + ")" +
                        ")";

    }

    public static abstract class Dives implements BaseColumns {

        public static final String TABLE_NAME = "dives";
        public static final String COLUMN_NAME_STARTTIME = "starttime";
        public static final String COLUMN_NAME_DURATION = "duration"; // (s)
        public static final String COLUMN_NAME_SITE_ID = "site_id";
        public static final String COLUMN_NAME_DIVER_ID = "diver_id";
        public static final String COLUMN_NAME_SURFACEINTERVAL = "surfaceinterval"; // (s)
        public static final String COLUMN_NAME_MAXDEPTH = "maxdepth"; // (m)
        public static final String COLUMN_NAME_AVGDEPTH = "avgdepth"; // (m)
        public static final String COLUMN_NAME_AIRTEMP = "airtemp"; // (°C)
        public static final String COLUMN_NAME_SURFACETEMP = "surfacetemp"; // (°C)
        public static final String COLUMN_NAME_BOTTOMTEMP = "bottomtemp"; // (°C)
        public static final String COLUMN_NAME_TANKVOLUME = "tankvolume"; // (l)
        public static final String COLUMN_NAME_STARTPRESSURE = "startpressure"; // (bar)
        public static final String COLUMN_NAME_ENDPRESSURE = "endpressure"; // (bar)
        public static final String COLUMN_NAME_WEIGHT = "weight"; // (kg)
        public static final String COLUMN_NAME_O2PERCENTAGE = "o2percentage"; // (%)
        public static final String COLUMN_NAME_BUDDY_ID = "buddy_id";
        public static final String COLUMN_NAME_TRIP_ID = "trip_id";
        public static final String COLUMN_NAME_LOGNOTES = "lognotes";

        public static final String[] AllColumns = {
                Dives._ID,
                Dives.COLUMN_NAME_STARTTIME,
                Dives.COLUMN_NAME_DURATION,
                Dives.COLUMN_NAME_SITE_ID,
                Dives.COLUMN_NAME_DIVER_ID,
                Dives.COLUMN_NAME_SURFACEINTERVAL,
                Dives.COLUMN_NAME_MAXDEPTH,
                Dives.COLUMN_NAME_AVGDEPTH,
                Dives.COLUMN_NAME_AIRTEMP,
                Dives.COLUMN_NAME_SURFACETEMP,
                Dives.COLUMN_NAME_BOTTOMTEMP,
                Dives.COLUMN_NAME_TANKVOLUME,
                Dives.COLUMN_NAME_STARTPRESSURE,
                Dives.COLUMN_NAME_ENDPRESSURE,
                Dives.COLUMN_NAME_WEIGHT,
                Dives.COLUMN_NAME_O2PERCENTAGE,
                Dives.COLUMN_NAME_BUDDY_ID,
                Dives.COLUMN_NAME_TRIP_ID,
                Dives.COLUMN_NAME_LOGNOTES
        };
        
        public static final String SQL_DELETE_TABLE =
                "DROP TABLE IF EXISTS " + TABLE_NAME;
                
        public static final String SQL_CREATE_TABLE =
                "CREATE TABLE " + TABLE_NAME + " (" +
                        _ID + IPK_TYPE + COMMA_SEP +
                        COLUMN_NAME_STARTTIME + DATETIME_TYPE + NOTNULL_CONSTRAINT + COMMA_SEP +
                        COLUMN_NAME_DURATION + INTEGER_TYPE + NOTNULL_CONSTRAINT + COMMA_SEP +
                        COLUMN_NAME_SITE_ID + INTEGER_TYPE + NOTNULL_CONSTRAINT + COMMA_SEP +
                        COLUMN_NAME_DIVER_ID + INTEGER_TYPE + NOTNULL_CONSTRAINT + COMMA_SEP +
                        COLUMN_NAME_SURFACEINTERVAL + INTEGER_TYPE + COMMA_SEP +
                        COLUMN_NAME_MAXDEPTH + DEPTH_TYPE + COMMA_SEP +
                        COLUMN_NAME_AVGDEPTH + DEPTH_TYPE + COMMA_SEP +
                        COLUMN_NAME_AIRTEMP + INTEGER_TYPE + COMMA_SEP +
                        COLUMN_NAME_SURFACETEMP + INTEGER_TYPE + COMMA_SEP +
                        COLUMN_NAME_BOTTOMTEMP + INTEGER_TYPE + COMMA_SEP +
                        COLUMN_NAME_TANKVOLUME + INTEGER_TYPE + COMMA_SEP +
                        COLUMN_NAME_STARTPRESSURE + INTEGER_TYPE + COMMA_SEP +
                        COLUMN_NAME_ENDPRESSURE + INTEGER_TYPE + COMMA_SEP +
                        COLUMN_NAME_WEIGHT + WEIGHT_TYPE + COMMA_SEP +
                        COLUMN_NAME_O2PERCENTAGE + INTEGER_TYPE + COMMA_SEP +
                        COLUMN_NAME_BUDDY_ID + INTEGER_TYPE + COMMA_SEP +
                        COLUMN_NAME_TRIP_ID + INTEGER_TYPE + COMMA_SEP +
                        COLUMN_NAME_LOGNOTES + TEXT_TYPE + COMMA_SEP +
                        UNIQUE_CONSTRAINT + "(" + COLUMN_NAME_STARTTIME + COMMA_SEP + COLUMN_NAME_DIVER_ID + ")" + COMMA_SEP +
                        FOREIGNKEY_CONSTRAINT + "(" + COLUMN_NAME_SITE_ID + ")" + " REFERENCES " + DiveSites.TABLE_NAME + "(" + DiveSites._ID + ")" + COMMA_SEP +
                        FOREIGNKEY_CONSTRAINT + "(" + COLUMN_NAME_DIVER_ID + ")" + " REFERENCES " + Divers.TABLE_NAME + "(" + Divers._ID + ")" + COMMA_SEP +
                        FOREIGNKEY_CONSTRAINT + "(" + COLUMN_NAME_BUDDY_ID + ")" + " REFERENCES " + DiveBuddies.TABLE_NAME + "(" + DiveBuddies._ID + ")" + COMMA_SEP +
                        FOREIGNKEY_CONSTRAINT + "(" + COLUMN_NAME_TRIP_ID + ")" + " REFERENCES " + DiveTrips.TABLE_NAME + "(" + DiveTrips._ID + ")" +
                        ")";
    }

    public static abstract class DiveOrganizations implements BaseColumns {

        public static final String TABLE_NAME = "diveorganizations";
        public static final String COLUMN_NAME_NAME = "name";
        public static final String COLUMN_NAME_FULLNAME = "fullname";

        public static final String[] AllColumns = {
                DiveOrganizations._ID,
                DiveOrganizations.COLUMN_NAME_NAME,
                DiveOrganizations.COLUMN_NAME_FULLNAME,
        };
        
        public static final String SQL_DELETE_TABLE =
                "DROP TABLE IF EXISTS " + TABLE_NAME;
                
        public static final String SQL_CREATE_TABLE =
                "CREATE TABLE " + TABLE_NAME + "(" +
                        _ID + IPK_TYPE + COMMA_SEP +
                        COLUMN_NAME_NAME + TEXT_TYPE + UNIQUE_CONSTRAINT + NOTNULL_CONSTRAINT + COMMA_SEP +
                        COLUMN_NAME_FULLNAME + TEXT_TYPE + UNIQUE_CONSTRAINT +
                        ")";

    }

    public static abstract class DiveCourses implements BaseColumns {

        public static final String TABLE_NAME = "divecourses";
        public static final String COLUMN_NAME_NAME = "name";
        public static final String COLUMN_NAME_ORGANIZATION_ID = "organization_id";

        public static final String[] AllColumns = {
                DiveCourses._ID,
                DiveCourses.COLUMN_NAME_NAME,
                DiveCourses.COLUMN_NAME_ORGANIZATION_ID
        };
        
        public static final String SQL_DELETE_TABLE =
                "DROP TABLE IF EXISTS " + TABLE_NAME;
                
        public static final String SQL_CREATE_TABLE =
                "CREATE TABLE " + TABLE_NAME + "(" +
                        _ID + IPK_TYPE + COMMA_SEP +
                        COLUMN_NAME_NAME + TEXT_TYPE + NOTNULL_CONSTRAINT + COMMA_SEP +
                        COLUMN_NAME_ORGANIZATION_ID + INTEGER_TYPE + NOTNULL_CONSTRAINT + COMMA_SEP +
                        UNIQUE_CONSTRAINT + "(" + COLUMN_NAME_NAME + COMMA_SEP + COLUMN_NAME_ORGANIZATION_ID + ")" + COMMA_SEP +
                        FOREIGNKEY_CONSTRAINT + "(" + COLUMN_NAME_ORGANIZATION_ID + ")" + " REFERENCES " + DiveOrganizations.TABLE_NAME + "(" + DiveOrganizations._ID + ")" +
                        ")";

    }

    public static abstract class DiveCertifications implements BaseColumns {

        public static final String TABLE_NAME = "divecertifications";
        public static final String COLUMN_NAME_DATE = "date";
        public static final String COLUMN_NAME_DIVER_ID = "diver_id";
        public static final String COLUMN_NAME_COURSE_ID = "course_id";
        public static final String COLUMN_NAME_CENTER_ID = "center_id";
        public static final String COLUMN_NAME_NUMBER = "number";

        public static final String[] AllColumns = {
                DiveCertifications._ID,
                DiveCertifications.COLUMN_NAME_DATE,
                DiveCertifications.COLUMN_NAME_DIVER_ID,
                DiveCertifications.COLUMN_NAME_COURSE_ID,
                DiveCertifications.COLUMN_NAME_CENTER_ID,
                DiveCertifications.COLUMN_NAME_NUMBER
        };
        
        public static final String SQL_DELETE_TABLE =
                "DROP TABLE IF EXISTS " + TABLE_NAME;
                
        public static final String SQL_CREATE_TABLE =
                "CREATE TABLE " + TABLE_NAME + "(" +
                        _ID + IPK_TYPE + COMMA_SEP +
                        COLUMN_NAME_DATE + DATE_TYPE + NOTNULL_CONSTRAINT + COMMA_SEP +
                        COLUMN_NAME_DIVER_ID + INTEGER_TYPE + NOTNULL_CONSTRAINT + COMMA_SEP +
                        COLUMN_NAME_COURSE_ID + INTEGER_TYPE + NOTNULL_CONSTRAINT + COMMA_SEP +
                        COLUMN_NAME_CENTER_ID + INTEGER_TYPE + NOTNULL_CONSTRAINT + COMMA_SEP +
                        COLUMN_NAME_NUMBER + TEXT_TYPE + COMMA_SEP +
                        UNIQUE_CONSTRAINT + "(" + COLUMN_NAME_DIVER_ID + COMMA_SEP + COLUMN_NAME_COURSE_ID + ")" + COMMA_SEP +
                        FOREIGNKEY_CONSTRAINT + "(" + COLUMN_NAME_DIVER_ID + ")" + " REFERENCES " + Divers.TABLE_NAME + "(" + Divers._ID + ")" + COMMA_SEP +
                        FOREIGNKEY_CONSTRAINT + "(" + COLUMN_NAME_COURSE_ID + ")" + " REFERENCES " + DiveCourses.TABLE_NAME + "(" + DiveCourses._ID + ")" + COMMA_SEP +
                        FOREIGNKEY_CONSTRAINT + "(" + COLUMN_NAME_CENTER_ID + ")" + " REFERENCES " + DiveCenters.TABLE_NAME + "(" + DiveCenters._ID + ")" +
                        ")";

    }

    public static abstract class DiveCenters implements BaseColumns {

        public static final String TABLE_NAME = "divecenters";
        public static final String COLUMN_NAME_NAME = "name";
        public static final String COLUMN_NAME_LOCATION_ID = "location_id";
        public static final String COLUMN_NAME_WEBSITE = "website";

        public static final String[] AllColumns = {
                DiveCenters._ID,
                DiveCenters.COLUMN_NAME_NAME,
                DiveCenters.COLUMN_NAME_LOCATION_ID,
                DiveCenters.COLUMN_NAME_WEBSITE
        };
        
        public static final String SQL_DELETE_TABLE =
                "DROP TABLE IF EXISTS " + TABLE_NAME;
                
        public static final String SQL_CREATE_TABLE =
                "CREATE TABLE " + TABLE_NAME + "(" +
                        _ID + IPK_TYPE + COMMA_SEP +
                        COLUMN_NAME_NAME + TEXT_TYPE + NOTNULL_CONSTRAINT + COMMA_SEP +
                        COLUMN_NAME_LOCATION_ID + INTEGER_TYPE + NOTNULL_CONSTRAINT + COMMA_SEP +
                        COLUMN_NAME_WEBSITE + TEXT_TYPE + COMMA_SEP +
                        UNIQUE_CONSTRAINT + "(" + COLUMN_NAME_NAME + COMMA_SEP + COLUMN_NAME_LOCATION_ID + ")" + COMMA_SEP +
                        FOREIGNKEY_CONSTRAINT + "(" + COLUMN_NAME_LOCATION_ID + ")" + " REFERENCES " + DiveLocations.TABLE_NAME + "(" + DiveLocations._ID + ")" +
                        ")";

    }

    public static abstract class DiveLocations implements BaseColumns {

        public static final String TABLE_NAME = "divelocations";
        public static final String COLUMN_NAME_NAME = "name";
        public static final String COLUMN_NAME_COUNTRY_ID = "country_id";
        public static final String COLUMN_NAME_LATITUDE = "latitude";
        public static final String COLUMN_NAME_LONGITUDE = "longitude";

        public static final String[] AllColumns = {
                DiveLocations._ID,
                DiveLocations.COLUMN_NAME_NAME,
                DiveLocations.COLUMN_NAME_COUNTRY_ID,
                DiveLocations.COLUMN_NAME_LATITUDE,
                DiveLocations.COLUMN_NAME_LONGITUDE
        };
        
        public static final String SQL_DELETE_TABLE =
                "DROP TABLE IF EXISTS " + TABLE_NAME;
                
        public static final String SQL_CREATE_TABLE =
                "CREATE TABLE " + TABLE_NAME + "(" +
                        _ID + IPK_TYPE + COMMA_SEP +
                        COLUMN_NAME_NAME + TEXT_TYPE + NOTNULL_CONSTRAINT + COMMA_SEP +
                        COLUMN_NAME_COUNTRY_ID + INTEGER_TYPE + NOTNULL_CONSTRAINT + COMMA_SEP +
                        COLUMN_NAME_LATITUDE + COORDINATE_TYPE + NOTNULL_CONSTRAINT + COMMA_SEP +
                        COLUMN_NAME_LONGITUDE + COORDINATE_TYPE + NOTNULL_CONSTRAINT + COMMA_SEP +
                        UNIQUE_CONSTRAINT + "(" + COLUMN_NAME_NAME + COMMA_SEP + COLUMN_NAME_COUNTRY_ID + ")" + COMMA_SEP +
                        FOREIGNKEY_CONSTRAINT + "(" + COLUMN_NAME_COUNTRY_ID + ")" + " REFERENCES " + DiveCountries.TABLE_NAME + "(" + DiveCountries._ID + ")" +
                        ")";

    }

    public static abstract class DiveCountries implements BaseColumns {

        public static final String TABLE_NAME = "divecountries";
        public static final String COLUMN_NAME_NAME = "name";

        public static final String[] AllColumns = {
                DiveCountries._ID,
                DiveCountries.COLUMN_NAME_NAME
        };
        
        public static final String SQL_DELETE_TABLE =
                "DROP TABLE IF EXISTS " + TABLE_NAME;
                
        public static final String SQL_CREATE_TABLE =
                "CREATE TABLE " + TABLE_NAME + "(" +
                        _ID + IPK_TYPE + COMMA_SEP +
                        COLUMN_NAME_NAME + TEXT_TYPE + NOTNULL_CONSTRAINT + UNIQUE_CONSTRAINT +
                        ")";

    }

    public static abstract class DiveSites implements BaseColumns {

        public static final String TABLE_NAME = "divesites";
        public static final String COLUMN_NAME_NAME = "name";
        public static final String COLUMN_NAME_LOCATION_ID = "location_id";

        public static final String[] AllColumns = {
                DiveSites._ID,
                DiveSites.COLUMN_NAME_NAME,
                DiveSites.COLUMN_NAME_LOCATION_ID
        };
        
        public static final String SQL_DELETE_TABLE =
                "DROP TABLE IF EXISTS " + TABLE_NAME;
                
        public static final String SQL_CREATE_TABLE =
                "CREATE TABLE " + TABLE_NAME + "(" +
                        _ID + IPK_TYPE + COMMA_SEP +
                        COLUMN_NAME_NAME + TEXT_TYPE + NOTNULL_CONSTRAINT + UNIQUE_CONSTRAINT + COMMA_SEP +
                        COLUMN_NAME_LOCATION_ID + INTEGER_TYPE + NOTNULL_CONSTRAINT + COMMA_SEP +
                        FOREIGNKEY_CONSTRAINT + "(" + COLUMN_NAME_LOCATION_ID + ")" + " REFERENCES " + DiveLocations.TABLE_NAME + "(" + DiveLocations._ID + ")" +
                        ")";

    }

    public static abstract class DiveTrips implements BaseColumns {

        public static final String TABLE_NAME = "divetrips";
        public static final String COLUMN_NAME_DESTINATION = "destination";

        public static final String[] AllColumns = {
                DiveTrips._ID,
                DiveTrips.COLUMN_NAME_DESTINATION
        };

        public static final String SQL_DELETE_TABLE =
                "DROP TABLE IF EXISTS " + TABLE_NAME;

        public static final String SQL_CREATE_TABLE =
                "CREATE TABLE " + TABLE_NAME + "(" +
                        _ID + IPK_TYPE + COMMA_SEP +
                        COLUMN_NAME_DESTINATION + TEXT_TYPE + NOTNULL_CONSTRAINT + UNIQUE_CONSTRAINT +
                        ")";

    }

    public static abstract class DiveBuddies implements BaseColumns {

        public static final String TABLE_NAME = "divebuddies";
        public static final String COLUMN_NAME_NAME = "name";
        public static final String COLUMN_NAME_DIVER_ID = "diver_id";

        public static final String[] AllColumns = {
                DiveBuddies._ID,
                DiveBuddies.COLUMN_NAME_NAME,
                DiveBuddies.COLUMN_NAME_DIVER_ID
        };

        public static final String SQL_DELETE_TABLE =
                "DROP TABLE IF EXISTS " + TABLE_NAME;

        public static final String SQL_CREATE_TABLE =
                "CREATE TABLE " + TABLE_NAME + "(" +
                        _ID + IPK_TYPE + COMMA_SEP +
                        COLUMN_NAME_NAME + TEXT_TYPE + NOTNULL_CONSTRAINT + UNIQUE_CONSTRAINT + COMMA_SEP +
                        COLUMN_NAME_DIVER_ID + INTEGER_TYPE + COMMA_SEP +
                        FOREIGNKEY_CONSTRAINT + "(" + COLUMN_NAME_DIVER_ID + ")" + " REFERENCES " + Divers.TABLE_NAME + "(" + Divers._ID + ")" +
                        ")";

    }
    
    public static abstract class DiveSamples implements BaseColumns {

        public static final String TABLE_NAME = "divesamples";
        public static final String COLUMN_NAME_DIVE_ID = "dive_id";
        public static final String COLUMN_NAME_SAMPLETIME = "sampletime";
        public static final String COLUMN_NAME_DEPTH = "depth";
        public static final String COLUMN_NAME_PRESSURE = "pressure";
        public static final String COLUMN_NAME_TEMPERATURE = "temperature";
        public static final String COLUMN_NAME_BOOKMARK = "bookmark";
        public static final String COLUMN_NAME_BOOKMARKTEXT = "bookmarktext";
        public static final String COLUMN_NAME_SACRATE = "sacrate";
        public static final String COLUMN_NAME_CYLINDERPRESSURE = "cylinderpressure";

        public static final String[] AllColumns = {
                DiveSamples._ID,
                DiveSamples.COLUMN_NAME_DIVE_ID,
                DiveSamples.COLUMN_NAME_SAMPLETIME,
                DiveSamples.COLUMN_NAME_DEPTH,
                DiveSamples.COLUMN_NAME_PRESSURE,
                DiveSamples.COLUMN_NAME_TEMPERATURE,
                DiveSamples.COLUMN_NAME_BOOKMARK,
                DiveSamples.COLUMN_NAME_BOOKMARKTEXT,
                DiveSamples.COLUMN_NAME_SACRATE,
                DiveSamples.COLUMN_NAME_CYLINDERPRESSURE
        };
        
        public static final String SQL_DELETE_TABLE =
                "DROP TABLE IF EXISTS " + TABLE_NAME;
                
        public static final String SQL_CREATE_TABLE =
                "CREATE TABLE " + TABLE_NAME + " (" +
                        _ID + IPK_TYPE + COMMA_SEP +
                        COLUMN_NAME_DIVE_ID + INTEGER_TYPE + NOTNULL_CONSTRAINT + COMMA_SEP +
                        COLUMN_NAME_SAMPLETIME + INTEGER_TYPE + NOTNULL_CONSTRAINT + COMMA_SEP +
                        COLUMN_NAME_DEPTH + DEPTH_TYPE + NOTNULL_CONSTRAINT + COMMA_SEP +
                        COLUMN_NAME_PRESSURE + INTEGER_TYPE + NOTNULL_CONSTRAINT + COMMA_SEP +
                        COLUMN_NAME_TEMPERATURE + INTEGER_TYPE + NOTNULL_CONSTRAINT + COMMA_SEP +
                        COLUMN_NAME_BOOKMARK + INTEGER_TYPE + NOTNULL_CONSTRAINT + COMMA_SEP +
                        COLUMN_NAME_BOOKMARKTEXT + TEXT_TYPE + COMMA_SEP +
                        COLUMN_NAME_SACRATE + REAL_TYPE + NOTNULL_CONSTRAINT + COMMA_SEP +
                        COLUMN_NAME_CYLINDERPRESSURE + INTEGER_TYPE + NOTNULL_CONSTRAINT + COMMA_SEP +
                        FOREIGNKEY_CONSTRAINT + "(" + COLUMN_NAME_DIVE_ID + ")" + " REFERENCES " + Dives.TABLE_NAME + "(" + Dives._ID + ")" +
                        ")";
    }

}